home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 2000 …ember: Reference Library / Dev.CD Dec 00 RL Disk 1.toast / pc / technical documentation / develop / develop issue 27 / develop issue 27 code / internet config assistant / internetassistant / tinternetassistantinterview.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-06-30  |  1.9 KB  |  90 lines

  1. /*
  2.     File:        TInternetAssistantDialog.cp
  3.  
  4.     Contains:    Subclass of CDialogs which offer multiple pages
  5.  
  6.     Written by:    Arno Gourdol
  7.  
  8.     Copyright:    © 1996 by Apple Computer, Inc., all rights reserved.
  9.  
  10. */
  11.  
  12. #pragma once
  13.  
  14. #ifndef __TINTERNETASSISTANTDIALOG__
  15. #define __TINTERNETASSISTANTDIALOG__
  16.  
  17. #include "TAssistant.h"
  18. #include "CInternetConfig.h"
  19. #include "ICAPI.h"
  20.  
  21. #include "TMapView.h"
  22.  
  23. enum
  24. {
  25.     // ID of the STR resource in the system file containing the 
  26.     // name of the user
  27.     kUserNameSTR = -16096
  28. };
  29.  
  30.  
  31.  
  32. class TInternetAssistantDialog : public TAssistant
  33. {
  34. public:
  35.     enum 
  36.     {
  37.         kIntroPane = 201,
  38.         kPersonalInfoPane = 202,
  39.         kLocationPane = 203,
  40.         kEmailOnePane = 204,
  41.         kEmailTwoPane = 205,
  42.         kSignaturePane = 206,
  43.         kHomePagePane = 207,
  44.         kNNTPHostPane = 208,
  45.         kEmailError = 211
  46.     };
  47.     enum 
  48.     {
  49.         kUserNameField = kLastCommonItem + 1,
  50.         kOrganizationField = kLastCommonItem + 2,
  51.         kMapUserItem = kLastCommonItem + 1,
  52.         kEmailField = kLastCommonItem + 1,
  53.         kPasswordField = kLastCommonItem + 2,
  54.         kEmailAccountField = kLastCommonItem + 1,
  55.         kSMTPHostField = kLastCommonItem + 2,
  56.         kSignatureField = kLastCommonItem + 1,
  57.         kHomePageField = kLastCommonItem + 1,
  58.         kNNTPHostField = kLastCommonItem + 1
  59.     };
  60.     
  61.     // constructor
  62.     TInternetAssistantDialog(TApplication* application = NULL);
  63.         
  64.     // destructor
  65.     virtual ~TInternetAssistantDialog();        
  66.     
  67.     // events
  68.     virtual void DrawUserItem(TDrawContext& graphics, short item, const CRect& frame);
  69.     virtual void ItemHit(UInt16 subDialog, short item);
  70.     virtual void Pulse(void);
  71.     virtual Boolean FilterEvent(const EventRecord& event);
  72.     virtual Boolean FilterKey(const EventRecord& event, UInt16 key);
  73.     
  74.     // dialog managment
  75.     virtual void SetDialogPane(SInt16 pane);
  76.     
  77.     void GetDefaultValues(void);
  78.     virtual void GoAhead(void);
  79.     virtual Boolean SkipPane(SInt16 pane);
  80.     virtual SInt16 NextPane(SInt16 currentPane);
  81.  
  82. private:
  83.     CInternetConfig fInternetConfig;
  84.     TMapView fMap;
  85.     Str255 fPassword;
  86.     Boolean fPasswordChanged;
  87. };
  88.  
  89. #endif
  90.